package EDesign23;

public class DProxy {

    public interface RealEstate {
        void sell();
    }

    public class Seller implements RealEstate {
        @Override
        public void sell() {
            System.out.println("卖了房子");
        }
    }

    public class SellerProxy implements RealEstate{
        private Seller seller;
        @Override
        public void sell() {
            if(seller==null){
                seller = new Seller();
            }

            seller.sell();

            System.out.println("退税办理完毕");
        }
    }



}
